Skip to content

fix(rewrite): handle process wrapper prefixes#2568

Open
YOMXXX wants to merge 1 commit into
rtk-ai:developfrom
YOMXXX:fix/issue-2375-process-wrappers
Open

fix(rewrite): handle process wrapper prefixes#2568
YOMXXX wants to merge 1 commit into
rtk-ai:developfrom
YOMXXX:fix/issue-2375-process-wrappers

Conversation

@YOMXXX

@YOMXXX YOMXXX commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Teach rewrite to peel process-wrapper prefixes (timeout, time, nice, nohup, stdbuf) and rewrite the inner supported command.
  • Preserve wrapper options, env prefixes, and compound command segments while leaving incomplete wrappers passthrough.
  • Add regression coverage for wrapped cargo/git commands, timeout options, env composition, and missing inner commands.

Fixes #2375

Verification

  • cargo +1.93.0 test process_wrapper -- --nocapture
  • cargo +1.93.0 test prefix -- --nocapture
  • cargo +1.93.0 fmt --all -- --check
  • cargo +1.93.0 clippy --all-targets
  • cargo +1.93.0 test --all -- --skip small_grep_not_worse_than_plain
  • git diff --check
  • cargo +1.93.0 run --quiet -- rewrite "timeout 300 cargo test" -> prints timeout 300 rtk cargo test and exits 3 per Ask verdict protocol

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Hook rewrite ignores process-wrapper prefixes (timeout, time) so wrapped commands run raw/unfiltered

1 participant